﻿using UnityEngine;
using UnityEngine.UIElements;
using winS.UnityEditor.UIElement;

namespace winS.UnityEditor.ProcessEditor
{
    public class NodeShadow : VisualElement
    {
        public const float shadowOffset = 8f;

        public static readonly Color defaultShadowColor = new Color32(0, 0, 0, 128);

        public NodeShadow()
        {
            name = "节点阴影";
            pickingMode = PickingMode.Ignore;
            style.SetBorderRadius(StepNode.nodeBorderRadius);
            style.SetBackgroundColor(defaultShadowColor);

            style.position = Position.Absolute;
            style.top = style.left = shadowOffset;
            style.bottom = style.right = -shadowOffset;
        }
    }
}